
{{ import:privacy_connect_core.js }}

var FormInspectorListener = function ()
{
	this.saveProfile = function(payload)
	{
		 prompt("JH:saveProfile", JSON.stringify(payload));
	}

	this.selectProfile = function(host)
	{
		return JSON.parse(prompt("JH:selectProfile", host));
	}

	this.formWillSubmit = function(profileToken, passwordFieldName)
	{
		prompt("JH:formWillSubmit", profileToken + "=!=" + passwordFieldName);
	}

	this.isOneClickEnabled = function()
	{
		return prompt("JH:isOneClickEnabled");
	}
};

var inspector = new IDGFormInspector(new FormInspectorListener());
inspector.inspectDom();
